﻿using System.ComponentModel.DataAnnotations;

namespace XLZF.MicroServices.Models;

public class Clothing_Users
{
    /// <summary>
    /// 用户ID
    /// </summary>
    [Key]
    [MaxLength(4)]
    public int UserID { get; set; }

    /// <summary>
    /// 登录名称
    /// </summary>

    [MaxLength(50)]
    public string LoginName { get; set; }

    /// <summary>
    /// 用户名称
    /// </summary>
    [MaxLength(100)]
    public string UserName { get; set; }

    /// <summary>
    /// 邮箱
    /// </summary>
    [MaxLength(50)]
    public string Email { get; set; }

    /// <summary>
    /// 用户密码
    /// </summary>
    [MaxLength(100)]
    public string Password { get; set; }

    /// <summary>
    /// 用户状态
    /// </summary>
    [MaxLength(1)]
    public int UserStatus { get; set; }

    /// <summary>
    /// 状态
    /// </summary>
    [MaxLength(1)]
    public int Status { get; set; }

    /// <summary>
    /// 创建人
    /// </summary>
    [MaxLength(100)]
    public string CreateBy { get; set; }

    /// <summary>
    /// 创建时间
    /// </summary>
    public DateTime CreateDate { get; set; }

    /// <summary>
    /// 修改人
    /// </summary>
    [MaxLength(100)]
    public string? UpdateBy { get; set; }

    /// <summary>
    /// 修改时间
    /// </summary>
    public DateTime? UpdateDate { get; set; }
}

/// <summary>
/// 注册信息
/// </summary>
public class Clothing_Register
{
    public string LoginName { get; set; }

    public string UserName { get; set; }

    public string LoginPwd { get; set; }

    public string Email { get; set; }
}


public class UserLoginView
{
    public string userName { get; set; }

    public string passWord { get; set; }
}

public class LoginedAccess
{
    public string TokenAccess { get; set; }

    public string NickName { get; set; }

    public string userid { get; set; }
}

public class LoginUserSub
{
    public string sub { get; set; }

    public string name { get; set; }

    public string preferred_username { get; set; }
}

/// <summary>
/// 修改密码数据模型
/// </summary>
public class ChangePassword
{
    /// <summary>
    /// 用户ID
    /// </summary>
    public string ID { get; set; }

    /// <summary>
    /// 用户当前密码
    /// </summary>
    public string currentPassword { get; set; }

    /// <summary>
    /// 用户新密码
    /// </summary>
    public string newPassword { get; set; }
}